package com.meituan.sdk.model.ddzhkh.miniprogram.tradeRefundOrder;

import com.meituan.sdk.annotations.ApiMeta;
import com.google.gson.reflect.TypeToken;
import javax.validation.constraints.NotBlank;
import java.lang.reflect.Type;
import com.meituan.sdk.internal.utils.JsonUtil;
import com.google.gson.annotations.SerializedName;
import javax.validation.constraints.NotNull;
import com.meituan.sdk.MeituanResponse;
import com.meituan.sdk.MeituanRequest;

/**
* 退款申请
* This file was automatically generated.
*/
@ApiMeta(
    path = "/ddzhkh/miniprogram/trade/refund_order",
    businessId = 59,
    apiVersion = "10004",
    apiName = "trade_refund_order",
    needAuth = true
)
public class TradeRefundOrderRequest implements MeituanRequest<TradeRefundOrderResponse> {
    @NotBlank(message = "generalBizData不能为空")
    @SerializedName("generalBizData")
    private String generalBizData;
    /**
    * <p data-diff-id="ct-diff-id-ea7b65a4-0f83-421f-8189-d3edd4743332">退款请求参数</p>
    */
    @NotNull(message = "refundOrderReq不能为空")
    @SerializedName("refundOrderReq")
    private RefundOrderReq refundOrderReq;

    public String getGeneralBizData() {
        return generalBizData;
    }
    public void setGeneralBizData(String generalBizData) {
        this.generalBizData = generalBizData;
    }
    public RefundOrderReq getRefundOrderReq() {
        return refundOrderReq;
    }
    public void setRefundOrderReq(RefundOrderReq refundOrderReq) {
        this.refundOrderReq = refundOrderReq;
    }


    @Override
    public MeituanResponse<TradeRefundOrderResponse> deserializeResponse(String response) {
        Type type = new TypeToken<MeituanResponse<TradeRefundOrderResponse>>(){}.getType();
        return JsonUtil.fromJson(response, type);
    }
    @Override
    public String serializeToJson() {
        return JsonUtil.toJson(this);
    }


    @Override
    public String toString() {
        return "TradeRefundOrderRequest{" + "generalBizData=" + generalBizData + "," + "refundOrderReq=" + refundOrderReq + "}";
    }
}
